
#include "win32_gl_context.h"

#include <stdlib.h> 
#include <stdio.h>
#include <string.h>
#include <math.h>
#include <tchar.h>

#include <GL/gl.h>
#include <GL/glext.h>
#include <GL/wglext.h>


// Global win32 OpenGL Video Context within DLL.
// Found in win32_GL_context.cpp
extern Win32_GL_Video_Context *gWin32GLContext;

// DLL entry function (called on load, unload, ...)
BOOL APIENTRY DllMain(HANDLE hModule, DWORD dwReason, LPVOID lpReserved)
{
    return TRUE;
}
 
// Exported function - adds two numbers
__declspec(dllexport) Humble_Video_Context* GetRenderContext()
{
	if( gWin32GLContext == NULL)
	{
		// Create Context.
		gWin32GLContext = new Win32_GL_Video_Context();
	}
    return gWin32GLContext;
}